package com.zhang.springcloud.sentinel;

import com.alibaba.csp.sentinel.slots.block.BlockException;
import com.zhang.springcloud.entities.CommonResult;

public class BlockHandler {
    //必须是静态方法
    public static CommonResult handleException(BlockException ex) {
            return new CommonResult(444,"按资源限定名称限流测试失败",ex.getClass().getCanonicalName());
    }
    public static CommonResult handleException1(BlockException ex) {
        return new CommonResult(444,"按资源限定名称限流测试失败---1",ex.getClass().getCanonicalName());
    }
}
